package com.hkts.naturalgas.feign;

import com.hkts.naturalgas.performance.performanceTo.HontUserTo;
import com.hkts.naturalgas.utils.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;
import java.util.Map;

/**
 * @ClassNameFeignInterface
 * @Description
 * @Author yck
 * @Date2020-12-07 10:58
 * @Version V1.0
 **/
@FeignClient(value="naturalgas-authentication",configuration = FeignHeadersInterceptor.class)
public interface FeignInterface {
    @GetMapping("/authentication/remoteUserInfo")
    public HontUserTo remoteUserInfo();

    //远程调用前台用户
    @GetMapping("/authentication/fontUserList")
    public List<HontUserTo> fontUserList();

    //远程调用前台用户数据权限
    @GetMapping("/authentication/getDepartmentIds")
    public List<String> getDepartmentIds();

    //远程调用拿到角色等级
    @GetMapping("/authentication/performanceUserInfo")
    public Result<Map<String,Object>> performanceUserInfo();

    @GetMapping ("/authentication/send")
    public String send(@RequestBody String[] openId);
    @GetMapping ("/authentication/test")
    public Map<String,Object> test();
    //流程结束后远程调用发送消息查阅信息
    @GetMapping ("/authentication/end")
    public String end(@RequestBody String[] o);

}
